package com.czx.service;

import com.czx.mapper.UserMapper;
import com.czx.pojo.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @package: com.czx.service
 * @ClassName: UserServiceimpl
 * @author: CZX.
 * @date: 2022/2/9 15:06
 */
@Service
public class UserServiceimpl implements UserService{
    @Autowired
    UserMapper userMapper;

    @Override
    public User login(String name, String pwd) {
        return userMapper.login(name, pwd);
    }

    @Override
    public boolean register(User user) {
        return userMapper.register(user)>0;
    }
}
